1. Field of the Invention
The preset invention relates to a robot controller for controlling a robot which supplies and discharges a workpiece to and from a machine tool.
2. Description of the Related Art
In a robot for supplying a material (or a workpiece) to a machine tool and for discharging the workpiece processed in the machine tool (or a product) from the machine tool, it is necessary that a robot controller for controlling the robot recognize a status of the machine tool, in order to determine the motion of the robot corresponding to the status of the machine tool.
As relevant prior art documents, JP S63-318237 A discloses a processing system having a lathe with a robot, wherein a signal is transmitted to the robot so that the robot and the lathe return to the respective origins before processing, when the lathe can no longer continue the processing due to termination of a life of a tool, etc.
JP H05-026628 B discloses a processing system wherein a workpiece is attached or detached by a robot when the workpiece is to be processed in an NC machine tool. JP H05-026628 B also discloses a means to output an alarm when a defect of the workpiece or failure of chucking the workpiece is detected so that appropriate measures can be automatically taken against the detect or failure by controlling the robot or chuck.
Further, JP H01-205964 A discloses a workpiece processing system wherein a plurality of cells, constituted by a plurality of machine tools and robots attached thereto, are controlled and operated by a host computer. In the processing system, processing patterns of deficiencies regarding a life and/or defect of the tool, etc., are previously stored in both the cells and the host computer, and the processing patterns are automatically executed when a deficiency occurs.
As described in JP S63-318237 A, in the prior art, a robot is informed of an abnormality of a machine tool by means of a signal, and then the robot carries out operations such as returning to the origin, taking out a workpiece and exchanging a tool, etc., corresponding to the input signal. However, when a signal is used, programming for assigning, defining and inputting/outputting of the signal is necessary in both the machine tool and the robot. In order to specify the motion of the robot in detail corresponding to the content of the abnormality in such a configuration, a burdensome operation such as increasing various signals is necessary. Further, after a production operation is started, it is difficult to add a signal or change a program, and thus it is difficult to judge a situation and add an operation corresponding to the situation.
JP H05-026628 B does not explicitly describe the usage of a signal. However, sine this document describes that a CPU is connected to a robot unit via a programmable controller, it can be understood that a signal is used to inform an abnormal situation. Therefore, the configuration of JP H05-026628 B has the same problem as in JP S63-318237 A.
On the other hand, in JP H01-205964 A, the processing cell is stopped in an emergency manner (i.e., a processed workpiece and a material workpiece are conveyed to a product pallet and a material pallet, respectively, and the lathe and the robot are returned to the respective origins) when a defect occurs in the cell, a signal informing the stoppage of the cell is transmitted to the host computer. Then, it is judged as to whether the processing can be restarted, a power-off command is confirmed, and process information regarding another lot is transmitted, etc. In other words, in JP H01-205964 A, the lathe and the robot are returned to the respective origins when an abnormality occurs in the processing cell, and after that, information regarding the motion of the entire cell is transmitted between the processing cell and the host computer. However, there are many kinds of abnormalities in an actual machine tool, and it is not always appropriate to stop the machine tool in an emergency (i.e., return the machine tool and the robot to the respective origins) regardless of the kind of abnormality.